home *** CD-ROM | disk | FTP | other *** search
Text File | 1996-01-24 | 7.4 KB | 307 lines | [TEXT/MPS ] |
- ;
- ; File: ASDebugging.a
- ;
- ; Contains: AppleScript Debugging Interfaces.
- ;
- ; Version: Technology: AppleScript 1.1
- ; Package: Universal Interfaces 2.2 in “MPW” on ETO #20
- ;
- ; Copyright: © 1984-1995 by Apple Computer, Inc.
- ; All rights reserved.
- ;
- ; Bugs?: If you find a problem with this file, use the Apple Bug Reporter
- ; stack. Include the file and version information (from above)
- ; in the problem description and send to:
- ; Internet: apple.bugs@applelink.apple.com
- ; AppleLink: APPLE.BUGS
- ;
- ;
-
- IF &TYPE('__ASDEBUGGING__') = 'UNDEFINED' THEN
- __ASDEBUGGING__ SET 1
-
-
- IF &TYPE('__APPLEEVENTS__') = 'UNDEFINED' THEN
- include 'AppleEvents.a'
- ENDIF
- ; include 'Errors.a' ;
- ; include 'ConditionalMacros.a' ;
- ; include 'Types.a' ;
- ; include 'Memory.a' ;
- ; include 'MixedMode.a' ;
- ; include 'OSUtils.a' ;
- ; include 'Events.a' ;
- ; include 'Quickdraw.a' ;
- ; include 'QuickdrawText.a' ;
- ; include 'EPPC.a' ;
- ; include 'AppleTalk.a' ;
- ; include 'Files.a' ;
- ; include 'Finder.a' ;
- ; include 'PPCToolbox.a' ;
- ; include 'Processes.a' ;
- ; include 'Notification.a' ;
-
- IF &TYPE('__APPLESCRIPT__') = 'UNDEFINED' THEN
- include 'AppleScript.a'
- ENDIF
- ; include 'OSA.a' ;
- ; include 'AEObjects.a' ;
- ; include 'Components.a' ;
- ; include 'TextEdit.a' ;
-
- ; This mode flag can be passed to OSASetProperty or OSASetHandler
- ; and will prevent properties or handlers from being defined in a context
- ; that doesn't already have bindings for them. An error is returned if
- ; a current binding doesn't already exist.
- kOSAModeDontDefine EQU $0001
-
- ;*************************************************************************
- ; Component Selectors
- ;*************************************************************************
- kASSelectSetPropertyObsolete EQU $1101
- kASSelectGetPropertyObsolete EQU $1101
- kASSelectSetHandlerObsolete EQU $1103
- kASSelectGetHandlerObsolete EQU $1104
- kASSelectGetAppTerminologyObsolete EQU $1105
- kASSelectSetProperty EQU $1106
- kASSelectGetProperty EQU $1107
- kASSelectSetHandler EQU $1108
- kASSelectGetHandler EQU $1109
- kASSelectGetAppTerminology EQU $110A
- kASSelectGetSysTerminology EQU $110B
- kASSelectGetPropertyNames EQU $110C
- kASSelectGetHandlerNames EQU $110D
-
- ;*************************************************************************
- ; Context Accessors
- ;*************************************************************************
- ;
- ; pascal OSAError OSASetProperty(ComponentInstance scriptingComponent, long modeFlags, OSAID contextID, const AEDesc *variableName, OSAID scriptValueID)
- ;
- IF ¬ GENERATINGCFM THEN
- Macro
- _OSASetProperty
- dc.w $2F3C
- dc.w $0010
- dc.w $1106
- moveq #0,d0
- dc.w $A82A
- EndM
- ELSE
- IMPORT_CFM_FUNCTION OSASetProperty
- ENDIF
-
- ;
- ; pascal OSAError OSAGetProperty(ComponentInstance scriptingComponent, long modeFlags, OSAID contextID, const AEDesc *variableName, OSAID *resultingScriptValueID)
- ;
- IF ¬ GENERATINGCFM THEN
- Macro
- _OSAGetProperty
- dc.w $2F3C
- dc.w $0010
- dc.w $1107
- moveq #0,d0
- dc.w $A82A
- EndM
- ELSE
- IMPORT_CFM_FUNCTION OSAGetProperty
- ENDIF
-
- ;
- ; pascal OSAError OSAGetPropertyNames(ComponentInstance scriptingComponent, long modeFlags, OSAID contextID, AEDescList *resultingPropertyNames)
- ;
- IF ¬ GENERATINGCFM THEN
- Macro
- _OSAGetPropertyNames
- dc.w $2F3C
- dc.w $000C
- dc.w $110C
- moveq #0,d0
- dc.w $A82A
- EndM
- ELSE
- IMPORT_CFM_FUNCTION OSAGetPropertyNames
- ENDIF
-
- ;
- ; pascal OSAError OSASetHandler(ComponentInstance scriptingComponent, long modeFlags, OSAID contextID, const AEDesc *handlerName, OSAID compiledScriptID)
- ;
- IF ¬ GENERATINGCFM THEN
- Macro
- _OSASetHandler
- dc.w $2F3C
- dc.w $0010
- dc.w $1108
- moveq #0,d0
- dc.w $A82A
- EndM
- ELSE
- IMPORT_CFM_FUNCTION OSASetHandler
- ENDIF
-
- ;
- ; pascal OSAError OSAGetHandler(ComponentInstance scriptingComponent, long modeFlags, OSAID contextID, const AEDesc *handlerName, OSAID *resultingCompiledScriptID)
- ;
- IF ¬ GENERATINGCFM THEN
- Macro
- _OSAGetHandler
- dc.w $2F3C
- dc.w $0010
- dc.w $1109
- moveq #0,d0
- dc.w $A82A
- EndM
- ELSE
- IMPORT_CFM_FUNCTION OSAGetHandler
- ENDIF
-
- ;
- ; pascal OSAError OSAGetHandlerNames(ComponentInstance scriptingComponent, long modeFlags, OSAID contextID, AEDescList *resultingHandlerNames)
- ;
- IF ¬ GENERATINGCFM THEN
- Macro
- _OSAGetHandlerNames
- dc.w $2F3C
- dc.w $000C
- dc.w $110D
- moveq #0,d0
- dc.w $A82A
- EndM
- ELSE
- IMPORT_CFM_FUNCTION OSAGetHandlerNames
- ENDIF
-
- ;
- ; pascal OSAError OSAGetAppTerminology(ComponentInstance scriptingComponent, long modeFlags, FSSpec *fileSpec, short terminologyID, Boolean *didLaunch, AEDesc *terminologyList)
- ;
- IF ¬ GENERATINGCFM THEN
- Macro
- _OSAGetAppTerminology
- dc.w $2F3C
- dc.w $0012
- dc.w $110A
- moveq #0,d0
- dc.w $A82A
- EndM
- ELSE
- IMPORT_CFM_FUNCTION OSAGetAppTerminology
- ENDIF
-
- ; Errors:
- ; errOSASystemError operation failed
- ;
- ;
- ; pascal OSAError OSAGetSysTerminology(ComponentInstance scriptingComponent, long modeFlags, short terminologyID, AEDesc *terminologyList)
- ;
- IF ¬ GENERATINGCFM THEN
- Macro
- _OSAGetSysTerminology
- dc.w $2F3C
- dc.w $000A
- dc.w $110B
- moveq #0,d0
- dc.w $A82A
- EndM
- ELSE
- IMPORT_CFM_FUNCTION OSAGetSysTerminology
- ENDIF
-
- ; Errors:
- ; errOSASystemError operation failed
- ;
- ; Notes on terminology ID
- ;
- ; A terminology ID is derived from script code and language code
- ; as follows;
- ;
- ; terminologyID = ((scriptCode & 0x7F) << 8) | (langCode & 0xFF)
- ;
- ;*************************************************************************
- ; Obsolete versions provided for backward compatibility:
- ;
- ;
- ; pascal OSAError ASSetProperty(ComponentInstance scriptingComponent, OSAID contextID, const AEDesc *variableName, OSAID scriptValueID)
- ;
- IF ¬ GENERATINGCFM THEN
- Macro
- _ASSetProperty
- dc.w $2F3C
- dc.w $000C
- dc.w $1101
- moveq #0,d0
- dc.w $A82A
- EndM
- ELSE
- IMPORT_CFM_FUNCTION ASSetProperty
- ENDIF
-
- ;
- ; pascal OSAError ASGetProperty(ComponentInstance scriptingComponent, OSAID contextID, const AEDesc *variableName, OSAID *resultingScriptValueID)
- ;
- IF ¬ GENERATINGCFM THEN
- Macro
- _ASGetProperty
- dc.w $2F3C
- dc.w $000C
- dc.w $1101
- moveq #0,d0
- dc.w $A82A
- EndM
- ELSE
- IMPORT_CFM_FUNCTION ASGetProperty
- ENDIF
-
- ;
- ; pascal OSAError ASSetHandler(ComponentInstance scriptingComponent, OSAID contextID, const AEDesc *handlerName, OSAID compiledScriptID)
- ;
- IF ¬ GENERATINGCFM THEN
- Macro
- _ASSetHandler
- dc.w $2F3C
- dc.w $000C
- dc.w $1103
- moveq #0,d0
- dc.w $A82A
- EndM
- ELSE
- IMPORT_CFM_FUNCTION ASSetHandler
- ENDIF
-
- ;
- ; pascal OSAError ASGetHandler(ComponentInstance scriptingComponent, OSAID contextID, const AEDesc *handlerName, OSAID *resultingCompiledScriptID)
- ;
- IF ¬ GENERATINGCFM THEN
- Macro
- _ASGetHandler
- dc.w $2F3C
- dc.w $000C
- dc.w $1104
- moveq #0,d0
- dc.w $A82A
- EndM
- ELSE
- IMPORT_CFM_FUNCTION ASGetHandler
- ENDIF
-
- ;
- ; pascal OSAError ASGetAppTerminology(ComponentInstance scriptingComponent, FSSpec *fileSpec, short terminologID, Boolean *didLaunch, AEDesc *terminologyList)
- ;
- IF ¬ GENERATINGCFM THEN
- Macro
- _ASGetAppTerminology
- dc.w $2F3C
- dc.w $000E
- dc.w $1105
- moveq #0,d0
- dc.w $A82A
- EndM
- ELSE
- IMPORT_CFM_FUNCTION ASGetAppTerminology
- ENDIF
-
- ; Errors:
- ; errOSASystemError operation failed
- ;
- ;************************************************************************
- ENDIF ; __ASDEBUGGING__
-